<?php
$v_recordtype_id = "";
if(isset($_REQUEST['hdn_recordtype_id'])){	
	$v_recordtype_id = $_REQUEST['hdn_recordtype_id'];
}

$v_recordtype_order =0;
if(isset($_REQUEST['hdn_max_order'])){	
	$v_recordtype_order = intval($_REQUEST['hdn_max_order'])+1;
}
if(_is_sqlserver()){
	//nieuvv--121108--lay ma phong ban phoi hop thu ly trong T_ONEGATE_CATE_CO_HANDLE
	$sql = "Exec Onegate_GetCateCoHandle  ";
	$sql = $sql ."'". $v_recordtype_id . "'" ;
	$ado_conn->SetFetchMode(ADODB_FETCH_ASSOC);
	$arr_cate_handle = $ado_conn->GetRow($sql);	
	//-the-end-nieuvv--121108--
	$sql = "Exec ONEGATE_RecordtypeGetSingle  ";
	$sql = $sql ."'". $v_recordtype_id . "'" ;
	//
	$sql_leav="Exec ONEGATE_RecordtypeGetSingle_Thue";
	$sql_leav = $sql_leav ."'". $v_recordtype_id . "'" ;
	//
	$ado_conn->SetFetchMode(ADODB_FETCH_ASSOC);
	$arr_single_recordtype = $ado_conn->GetRow($sql);
	$arr_single_recordtype_thue = $ado_conn->GetRow($sql_leav);
	
	/////Leav:12092008
	$sql_config = "Exec Onegate_ConfigRecordtypeGetSingle  ";
	$sql_config = $sql_config ."'". $v_recordtype_id . "'" ;
	$ado_conn->SetFetchMode(ADODB_FETCH_ASSOC);
	$arr_single_recordtype_config = $ado_conn->GetRow($sql_config);
	/////Leav:12092008_end
}?>